﻿using System;
using System.Collections.Generic;
using System.Linq;
using UnityEngine;


public class TweenActionCurve : TweenActionBase
{
    private TweenActionBase action;
    private AnimationCurve curve;

    public TweenActionCurve(TweenActionBase action,AnimationCurve curve)
    {
        this.curve = curve;
        this.action = action;
        totalTime = action.totalTime;
    }
    public override void OnStart()
    {
        action.OnStart();
    }
    public override void OnUpdate(float schedule) {
        action.OnUpdate(curve.Evaluate(schedule));
    }
}

